<!--#include('setting_summary.mossaic.html')-->

<div class="postMossaicMode">
<!--@foreach($document_list as $no=>$document_items)-->
	<div class="postCell<!--@if($no==count($document_list)-1)--> postCellEnd<!--@end-->" style="margin-bottom:{$mossaic_margin}px; <!--@if($mossaic_height>0)-->height:{$mossaic_height}px;<!--@end-->">	
	<!--@foreach($document_items as $no=>$document_data)-->
		{@
			$percent = $document_data['percent'];
			$document = $document_data['document'];
			
			$margin = $mossaic_margin;
			if($no == count($document_items)-1) $margin = 0;

			$width = floor($full_width * ($percent/100)) - $margin;
			
		}
		<div class="postWrap <!--@if($document->thumbnailExists())-->haveThumbnail<!--@else-->dontHaveThumbnail<!--@end-->" style="width:{$width}px; margin-right:{$margin}px;<!--@if(!$document->thumbnailExists())--> height:{$mossaic_thumbnail_height}px;<!--@end-->">
			<div class="postData <!--@if($summary_title_in_thumbnail)-->innerTitleMode<!--@end-->">
				<!--@if($document->thumbnailExists())-->
					<div class="thumbnail">
						<a href="{getUrl('document_srl',$document->document_srl,'cpage','')}"><img src="{$document->getThumbnail($width,$mossaic_thumbnail_height,'crop')}" class="summaryThumb" alt="" /></a>
					</div>
				<!--@end-->		
				
				<h2 class="postTitle"><span class="background"></span><a href="{getUrl('document_srl',$document->document_srl,'cpage','')}">{cut_str($document->getTitle(),40)}</a></h2>
				<!--@if($summary_cut_content>=0)-->
				{@ $summary = $document->getSummary($summary_cut_content)}
				<!--@if(!empty($summary))-->
				<div class="postContent">
					{$summary}
				</div>
				<!--@end-->
				<!--@end-->
			</div>
		</div>
	<!--@end-->
		<div class="clear"></div>
	</div>
<!--@end-->
</div>